﻿<%@ Page Title="" Language="C#" MasterPageFile="~/UserControl/MasterPage.Master"
    AutoEventWireup="true" CodeBehind="DanhSachSanPham.aspx.cs" Inherits="TMDT_Nhom1A.San_Pham.DanhSachSanPham" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<%@ Register Src="../UserControl/GioHang.ascx" TagName="GioHang" TagPrefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="module_round_box_inner">
        <div class="module_round_box_inner2">
            <div class="s5_mod_h3_1">
                <div class="s5_mod_h3_2">
                    <h3 class="s5_mod_h3">
                        <span class="s5_h3_first">
                            <asp:Label ID="lbCatalogue" runat="server" Text="Sản phẩm mới nhất"></asp:Label></span>
                    </h3>
                </div>
            </div>
            <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
            </asp:ToolkitScriptManager>
            <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <ContentTemplate>
                    <asp:DataList ID="dllistproducts" runat="server" RepeatColumns="3" RepeatDirection="Horizontal"
                        OnItemCommand="dllistproducts_ItemCommand" OnItemDataBound="dllistproducts_ItemDataBound">
                        <ItemTemplate>
                            <div style="text-align: center; width: 225px; cursor: default !importance">
                                <div class="s5_vm_name">
                                    <a>
                                        <asp:LinkButton ID="lbLinkToDetail" CommandName="lbLinkToDetail" CommandArgument='<%# Eval("ElectricDevice_ID") %>'
                                            runat="server"><%# Eval("ElectricDevice_ID") %></asp:LinkButton>
                                    </a>
                                    <%--<a href='<%# "ChiTietSanPham.aspx?ElectricDeviceID=" + Eval("ElectricDevice_ID") %>'>
                                <%# Eval("ElectricDevice_ID") %></a>--%>
                                    <br>
                                </div>
                                <div class="s5_vm_image">
                                    <asp:ImageButton ID="ibLinkToDetail" CommandName="ibLinkToDetail" CommandArgument='<%# Eval("ElectricDevice_ID") %>'
                                        Style="cursor: pointer" runat="server" ImageUrl='<%# Eval("ImagePath","../images/{0}") %>'
                                        ImageAlign="Middle" runat="server" />
                                </div>
                                <div style="clear: both">
                                </div>
                                <div class="s5_vm_price">
                                    <p>
                                        Số lượng :
                                        <asp:Label ID="Label2" runat="server" Text='<%# Eval("Quantity") %>'></asp:Label></p>
                                    <div id="nondel" runat="server">
                                        <p>
                                            Giá bán lẽ
                                            <asp:Label ID="lbRetailPrice" runat="server" Text='<%# Eval("RetailPrice") %>' Font-Bold="true"
                                                ForeColor="Red"></asp:Label>
                                            <asp:Label ID="Label3" runat="server" Text='<%# Eval("Currency_ID") %>'> </asp:Label></p>
                                        <p>
                                            Giá sĩ:
                                            <asp:Label ID="lbDealerPrice" runat="server" Text='<%# Eval("DealerPrice") %>' Font-Bold="true"
                                                ForeColor="Red"></asp:Label>
                                            <asp:Label ID="Label5" runat="server" Text='<%# Eval("Currency_ID") %>'> </asp:Label></p>
                                    </div>
                                    <div id="del" runat="server" visible="false">
                                        <p>
                                            Giá bán lẽ: <del>
                                                <asp:Label ID="Label8" runat="server" Text='<%# Eval("RetailPrice") %>' Font-Bold="true"
                                                    ForeColor="Red"></asp:Label></del>
                                            <asp:Label ID="Label9" runat="server" Text='<%# Eval("Currency_ID") %>'> </asp:Label></p>
                                        <p>
                                            Giá sĩ:<del>
                                                <asp:Label ID="Label10" runat="server" Text='<%# Eval("DealerPrice") %>' Font-Bold="true"
                                                    ForeColor="Red"></asp:Label></del>
                                            <asp:Label ID="Label11" runat="server" Text='<%# Eval("Currency_ID") %>'> </asp:Label></p>
                                    </div>
                                    <p runat="server" id="pPriceCoupon" visible="false">
                                        Giá coupon :
                                        <asp:Label ID="lbNonDiscountPrice" runat="server" Font-Bold="true" ForeColor="Red"></asp:Label>
                                        <asp:Label ID="Label6" runat="server" Text='<%# Eval("Currency_ID") %>'> </asp:Label></p>
                                    </p>
                                    <p runat="server" id="pNonDiscountPrice" visible="false">
                                        Giá coupon giảm :
                                        <asp:Label ID="lbDiscountPrice" runat="server" Font-Bold="true" ForeColor="Red"></asp:Label>
                                        <asp:Label ID="Label7" runat="server" Text='<%# Eval("Currency_ID") %>'> </asp:Label></p>
                                    </p>
                                </div>
                                <div class="s5_vm_add_to_cart">
                                    <p>
                                        Mua :
                                        <asp:TextBox ID="tbquantity" runat="server" Width="40px"></asp:TextBox>
                                        <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender1" TargetControlID="tbquantity"
                                            FilterType="Numbers" runat="server">
                                        </asp:FilteredTextBoxExtender>
                                        <asp:Button ID="Button1" CommandArgument='<%# Eval("ElectricDevice_ID")%>' CommandName="AddToCart"
                                            CssClass="addtocart_button" runat="server" Text="Thêm vào Giỏ" OnClientClick="if (!confirm('Bạn có muốn mua sản phẩm này không ?')) return false;" />
                                    </p>
                                </div>
                            </div>
                        </ItemTemplate>
                    </asp:DataList>
                </ContentTemplate>
            </asp:UpdatePanel>
        </div>
    </div>
</asp:Content>
<asp:Content ID="Content2" runat="server" ContentPlaceHolderID="ContentPlaceHolder2">
    <uc1:GioHang ID="GioHang1" runat="server" />
</asp:Content>
